<template>
    <div>
      <!-- 轮播图 -->
       <div class="swiper-container">
        <div class="swiper-wrapper">
          <div class="swiper-slide">
            <img src="@/assets/img/1.jpg" alt="">
          </div>
          <div class="swiper-slide">
            <img src="@/assets/img/2.jpg" style="height:280px" alt="">
          </div>
          <div class="swiper-slide">
            <img src="@/assets/img/3.jpg" style="height:280px" alt="">
          </div>
        </div>
        <!-- 如果需要分页器 -->
        <div class="swiper-pagination"></div>
      </div>
      <!-- 分类 -->
      <div class="classifl">
        <div class="classiflbox">
          <i class="el-icon-office-building"></i>
          <span class="title">新房</span>
          <span>优质生活 重新出发</span>
        </div>
        <div class="classiflbox">
          <i class="el-icon-house"></i>
          <span class="title">二手房</span>
          <span>真实房源 假一赔十</span>
        </div>
        <div class="classiflbox">
          <i class="el-icon-school"></i>
          <span class="title">租房</span>
          <span>舒适省心 租又何妨</span>
        </div>
        <div class="classiflbox">
          <i class="el-icon-wallet"></i>
          <span class="title">卖房</span>
          <span>足不出户 在线委托</span>
        </div>
      </div>
    </div>
</template>

<script>
import Swiper from 'swiper'
export default {
  name: 'ProjectFrontIndex',

  data () {
    return {

    }
  },

  mounted () {
    const swiper = new Swiper('.swiper-container', {
      loop: true, // 循环模式选项
      autoplay: true,
      // 如果需要分页器
      pagination: {
        el: '.swiper-pagination'
      },
      slidesPerView: 3,
      spaceBetween: 20
    })
    console.log(swiper)
  },

  methods: {

  }
}
</script>

<style lang="scss" scoped>
.classifl{
  width: 100%;
  height: 500px;
  background-color: rgb(245 243 243);
  display: flex;
  justify-content: space-around;
  align-items: center;
  .classiflbox{
    width: 200px;
    height: 200px;
    background-color: #fff;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    i{
      font-size: 30px;
    }
    .title{
      font-weight: bold;
      font-size: 16px;
    }
  }
}
</style>
